Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Other Parachain <> Darwinia <> Ethereum #1008

Merged
merged 235 commits into from
Mar 30, 2023
Merged

Conversation

jiguantong
Copy link
Member

@jiguantong jiguantong commented Mar 10, 2023

Closes #1062 #973

Develop

  • Add pallet-ethereum-xcm
  • Add pallet-xcm-transactor
  • Block production too long
  • Moonbeam 0.9.38
  • Astar XCM v3
  • DescendOrigin Barrier
  • Goerli Endpoint @wuminzhe
  • Darwinia Endpoint @wuminzhe

Astar > Goerli

  • Pangolin2 XCM > EVM
  • Astar XCM > Pangolin2 EVM
  • Astar XCM > Goerli deliver
  • Astar XCM > Goerli execution

Goerli > Astar

  • Goerli > Pangolin2 EVM
  • Pangolin2 EVM XCM > Astar
  • Goerli > Astar

Finishing work

AurevoirXavier and others added 30 commits November 4, 2022 16:28
* Skeleton

* XCM configs

* Bump toolchain

* Code cleaning part.1

* Code cleaning part.2

* Update SS58

* Rename

* Update token decimals

* Format

* Extract darwinia core primitives

* License

* Benchmarks

* Extract constants

* Docs

* CI part.1

* Adjust the runtime pallets structure (#29)

* frame-system

* pallet-timestamp

* pallet-authorship

* pallet-balances

* pallet-transaction-payment

* pallet-parachain-system

* pallet-parachain-info

* pallet-aura-ext

* pallet-xcmp-queue

* pallet-dmp-queue

* pallet-session

* pallet-aura

* pallet-collator-selection

* format

* deal ambiguous name

* fix compile

* clear imports

* update visibility for pallets

* add license for pallets

* update darwinia comments

* CI part.2

Signed-off-by: Xavier Lau <[email protected]>

* CI part.3

* CI part.4

* Add missing features

* Case

* Setup build environment

* CI part.5

* Enable `kusama-native`, `rococo-native`

Signed-off-by: Xavier Lau <[email protected]>
Co-authored-by: Guantong <[email protected]>
* Skeleton

* XCM configs

* Bump toolchain

* Code cleaning part.1

* Code cleaning part.2

* Update SS58

* Rename

* Update token decimals

* Format

* Extract darwinia core primitives

* Add frontier deps without fork!

* License

* Add pallets to runtime

* Benchmarks

* Append command part

* Extract constants

* Docs

* CI part.1

* Adjust the runtime pallets structure (#29)

* frame-system

* pallet-timestamp

* pallet-authorship

* pallet-balances

* pallet-transaction-payment

* pallet-parachain-system

* pallet-parachain-info

* pallet-aura-ext

* pallet-xcmp-queue

* pallet-dmp-queue

* pallet-session

* pallet-aura

* pallet-collator-selection

* format

* deal ambiguous name

* fix compile

* clear imports

* update visibility for pallets

* add license for pallets

* update darwinia comments

* Adapt main

* Delete duplicated consts

* Hack rpc

* Client compile fix

* Fix client

* Move to ethereum mod

* Add more precompile

* Fix some issue

* Solve conflict

* Merge issues

* Format

* Add basic code for precompiles

* Update EthRpcConfig

* Use Hashing type

* Foramt issue

* Adjust service config

* Add evm, ethereum feature

* Add missing features

* Move const

* Doc

* Format

* Format

* Format

* Format

* Format

* Safer truncated

* Clean importing

* Suppress warnings

* Remove empty line

* Clean importing

* Clean importing

* Format

* Clean importing

* Restructure

Co-authored-by: Xavier Lau <[email protected]>
Co-authored-by: Guantong <[email protected]>
* Use full path

* Abstract APIs & types

* Format
* Skeleton

* XCM configs

* Bump toolchain

* Code cleaning part.1

* Code cleaning part.2

* Update SS58

* Rename

* Update token decimals

* Format

* Extract darwinia core primitives

* License

* Benchmarks

* Extract constants

* Docs

* CI part.1

* Adjust the runtime pallets structure (#29)

* frame-system

* pallet-timestamp

* pallet-authorship

* pallet-balances

* pallet-transaction-payment

* pallet-parachain-system

* pallet-parachain-info

* pallet-aura-ext

* pallet-xcmp-queue

* pallet-dmp-queue

* pallet-session

* pallet-aura

* pallet-collator-selection

* format

* deal ambiguous name

* fix compile

* clear imports

* update visibility for pallets

* add license for pallets

* update darwinia comments

* CI part.2

Signed-off-by: Xavier Lau <[email protected]>

* CI part.3

* CI part.4

* Add missing features

* Case

* Setup build environment

* CI part.5

* init

* adjust structure & fix compile

* Move`type Barrier` out of `common` because of different runtimes may require different barriers

* Add required xcm barriers

* format

* remove redundant files

* format

* format

* try fix ci

* merge main

* fix ci

* Format

* remove unused dependencies

* format

* format

* format

* Format

Signed-off-by: Xavier Lau <[email protected]>
Co-authored-by: Xavier Lau <[email protected]>
* use full path

* RuntimeApi

Co-authored-by: Xavier Lau <[email protected]>
* Refactor `new_partial`

* Try fix compile

* Update `new_partial`

* Yeah, make compiler happy

* Code clean

* Something about command

* Resolve conflict

* Adapt for main style

* Self review

* Ready for review

* Revert full-path in command mod

* Code cleaning

Co-authored-by: Xavier Lau <[email protected]>
* Update ED

* Update `candidacy_bond`
* add messages-substrate deps

* fix ci

* add messages-substrate deps

* fix ci

* update messages-substrate deps

* update cargo.lock

* Format

Co-authored-by: Xavier Lau <[email protected]>
* Process state part.1

* More detail

* Take storages

* Take KV

* Merge balances

* Extract balance lock

* Format

* Flatten account

* Preprocess storage key

* Fix properties

* Add shell config

* Modularize processor

* Calculate total issuance

* Recover nonce
* Configure `H160` for runtime

* Configure `H160` genesis

Signed-off-by: Xavier Lau <[email protected]>

* Docs

* Improve code

* Add missing features

* Format and enable missing features for #50

* Format

* Fix evm config

* Revert the rename

Signed-off-by: Xavier Lau <[email protected]>
Co-authored-by: bear <[email protected]>
* More testing tokens

* Update runtime version

* Correct name
* Adjust genesis accounts

* Docs

* Typo
* Adjust runtime and add sudo

* Adjust parameter types and add vesting

* Fix compile

* Add utility

* Add collective, elections-phragmen, identity and treasury

* Add preimage and scheduler

* Add democracy and membership

* Add multisig and proxy

* License

* License

* Set balances's index to 5

* Code cleaning
* Add asset pallet

* Add asset precompile

* Add precompile interface

* Impl all asset precompile interfaces

* Self review

* Code clean

* Add mock file

* Fix test compile

* Add test 1

* Add test 2

* Add test 3

* Add test 4

* Finish test

* Add another type

* Update asset origin

* Fix CI

* Move out from Others

* Add asset to other runtimes
* Copy from Crab Parachain

* Replace Crab Parachain > Darwinia

* bridge pallets, many errors need to fix

� Conflicts:
�	Cargo.lock
�	runtime/common/Cargo.toml
�	runtime/darwinia/src/pallets/mod.rs

* Add fee_market

� Conflicts:
�	runtime/common/Cargo.toml

* Update deps

* Update deps

* Add bridge related pallets to darwinia

* Add bridge related pallets to crab

* format

* Update deps

* review

* comment

Co-authored-by: bear <[email protected]>
* Change paraId 1000 > 2105

* Darwinia paraId 2046
* Avoid large enum variant

* Fix tests

Co-authored-by: bear <[email protected]>
* Init commit

* Add todos

* Add `ValidateUnsigned`

* Add signature verify

* Add event

* Add comment

* Update message hash

* Add mock file

* Compile mock

* Add basic tests

* Add more tests

* Code clean

* Clean toml

* Format

* Install it to the runtimes

* Rename

Co-authored-by: HackFisher <[email protected]>
Co-authored-by: Xavier Lau <[email protected]>
* Handle reference count

* Fix test
* Housekeeping

* Format
* Bridge related pallets

* fee market

* format

* evm

* xcm

* format

* MaxMessagesToPruneAtOnce

* move ByteArray

* move AccountToAssetId

* move UniqueSaturatedInto

* Const

* format
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@@ -111,6 +109,11 @@ frame_support::parameter_types! {
pub UniversalLocation: InteriorMultiLocation = Parachain(ParachainInfo::parachain_id().into()).into();
// One XCM operation is 1_000_000_000 weight - almost certainly a conservative estimate.
pub UnitWeightCost: frame_support::weights::Weight = frame_support::weights::Weight::from_parts(1_000_000_000, 64 * 1024);
pub LocalAssetsPalletLocation: MultiLocation = MultiLocation::new(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused.

@@ -111,6 +109,11 @@ frame_support::parameter_types! {
pub UniversalLocation: InteriorMultiLocation = Parachain(ParachainInfo::parachain_id().into()).into();
// One XCM operation is 1_000_000_000 weight - almost certainly a conservative estimate.
pub UnitWeightCost: frame_support::weights::Weight = frame_support::weights::Weight::from_parts(1_000_000_000, 64 * 1024);
pub LocalAssetsPalletLocation: MultiLocation = MultiLocation::new(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused.

@@ -156,6 +156,7 @@ frame_support::construct_runtime! {

// EVM stuff.
Ethereum: pallet_ethereum = 36,
EthereumXcm: pallet_ethereum_xcm = 44,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

XCM, not EVM. Put it after the CumulusXcm .

@@ -157,6 +157,7 @@ frame_support::construct_runtime! {

// EVM stuff.
Ethereum: pallet_ethereum = 36,
EthereumXcm: pallet_ethereum_xcm = 44,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same

@@ -111,6 +109,11 @@ frame_support::parameter_types! {
pub UniversalLocation: InteriorMultiLocation = Parachain(ParachainInfo::parachain_id().into()).into();
// One XCM operation is 1_000_000_000 weight - almost certainly a conservative estimate.
pub UnitWeightCost: frame_support::weights::Weight = frame_support::weights::Weight::from_parts(1_000_000_000, 64 * 1024);
pub LocalAssetsPalletLocation: MultiLocation = MultiLocation::new(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused

@@ -157,6 +157,7 @@ frame_support::construct_runtime! {

// EVM stuff.
Ethereum: pallet_ethereum = 36,
EthereumXcm: pallet_ethereum_xcm = 44,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@AurevoirXavier
Copy link
Member

Should we add those things for Crab? This can be an issue.

@AurevoirXavier AurevoirXavier merged commit 03ecfc4 into main Mar 30, 2023
@AurevoirXavier AurevoirXavier deleted the guantong/xcm-evm branch March 30, 2023 16:27
@github-actions
Copy link

Check 9b20d44 pangoro-dev

Check runtime version

Check runtime storage

+ Pallet: "EthereumXcm"

@github-actions
Copy link

Check 9b20d44 pangolin-dev

Check runtime version

Check runtime storage

+ Pallet: "EthereumXcm"

@github-actions
Copy link

Check 9b20d44 crab-dev

Check runtime version

Check runtime storage

@github-actions
Copy link

Check 9b20d44 darwinia-dev

Check runtime version

Check runtime storage

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-XCM [Component] Something about XCM D-Frontier [Dependency] From Frontier D-Moonbeam [Dependency] From Moonbeam
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Connect Ethereum <> Other Parachains XCM to EVM
5 participants